package cn.xny.txcc.exception;

import cn.xny.txcc.code.ErrorCode;

public class BusinessException extends RuntimeException{

    String message;
    String code;

    public BusinessException() {
    }

    public BusinessException(String message) {
        super(message);
    }
    public BusinessException(ErrorCode errorCode) {
        super(errorCode.getMessage());
        this.code=errorCode.getCode();
        this.message=errorCode.getMessage();
    }
}
